package router

import (
	"fmt"
	"runtime/debug"
	"time"

	"admin/controller"

	"github.com/fasthttp/router"
	"github.com/valyala/fasthttp"
)

var (
	ApiTimeoutMsg = `{"code": 0,"msg":"服务器响应超时，请稍后重试"}`
	ApiTimeout    = time.Second * 30
	route         *router.Router
	buildInfo     BuildInfo
)

type BuildInfo struct {
	GitReversion   string
	BuildTime      string
	BuildGoVersion string
}

func apiServerPanic(ctx *fasthttp.RequestCtx, rcv interface{}) {
	err := rcv.(error)
	fmt.Println(err)
	debug.PrintStack()

	if r := recover(); r != nil {
		fmt.Println("recovered failed", r)
	}

	ctx.SetStatusCode(500)
	return
}

func Version(ctx *fasthttp.RequestCtx) {

	ctx.SetContentType("text/html; charset=utf-8")
	fmt.Fprintf(ctx, "reportApi<br />Git reversion = %s<br />Build Time = %s<br />Go version = %s<br />System Time = %s<br />",
		buildInfo.GitReversion, buildInfo.BuildTime, buildInfo.BuildGoVersion, ctx.Time())
	//ctx.Request.Header.VisitAll(func (key, value []byte) {
	//	fmt.Fprintf(ctx, "%s: %s<br/>", string(key), string(value))
	//})
}

// SetupRouter 设置路由列表
func SetupRouter(b BuildInfo) *router.Router {

	route = router.New()
	route.PanicHandler = apiServerPanic

	buildInfo = b

	commonGroup := route.Group("/api")
	tenantGroup := route.Group("/tenant")
	merchantGroup := route.Group("/merchant")
	businessGroup := route.Group("/business")

	//后台登陆
	loginCtl := new(controller.LoginController)
	post(tenantGroup, "/admin/login", loginCtl.AdminLogin)         //登陆--总后台
	post(merchantGroup, "/login", loginCtl.MerchantLogin)          //登陆--渠道后台
	post(businessGroup, "/login", loginCtl.BusinessLogin)          //登陆--业务员后台
	post(commonGroup, "/check/password", loginCtl.CheckPassword)   //验证密码
	post(commonGroup, "/change/password", loginCtl.ChangePassword) //修改密码
	post(commonGroup, "/getAuth", loginCtl.GetMenu)                //获取侧边栏
	get(commonGroup, "/export/excel", loginCtl.DownloadExcel)      //下载excel
	get(commonGroup, "/gettime", loginCtl.GetTime)                 //获取时间
	get(commonGroup, "/statistics", loginCtl.Statistics)           //获取整个平台redis 流水盈亏

	post(commonGroup, "/gettotaldata", loginCtl.Gettotaldata) //综合查询后台获取数据
	post(commonGroup, "/to/merchant2", loginCtl.ToMerchant2)  //

	// 日况数据修复
	//日况报表统计，游戏日况统计
	reportDailyCtl := new(controller.ReportDailyController)
	get(commonGroup, "/report/fixdailydata", reportDailyCtl.FixDaily)

	get(commonGroup, "/report/fixgamedaily", reportDailyCtl.FixGmaeDailyData)
	//首页+统计分析
	statisticsCtl := new(controller.StatisticsController)

	post(commonGroup, "/statistics/total/data", statisticsCtl.TotalData) //总统计

	post(commonGroup, "/statistics/daily/list", statisticsCtl.DailyList)   //日况统计概要
	post(commonGroup, "/statistics/game/settle", statisticsCtl.GameSettle) //游戏盈亏结算

	post(commonGroup, "/statistics/user/game/settle", statisticsCtl.UserGameSettle)   //玩家游戏盈亏结算
	post(commonGroup, "/statistics/user/game/monitor", statisticsCtl.UserGameMonitor) //游戏生态监控
	post(commonGroup, "/statistics/user/remain", statisticsCtl.UserRemain)            //留存报表

	//玩家管理
	memberCtl := new(controller.MemberController)
	post(commonGroup, "/member/list", memberCtl.List)     //所有玩家
	post(commonGroup, "/member/detail", memberCtl.Detail) //玩家详情

	post(commonGroup, "/report/userdaily", reportDailyCtl.UserList) //玩家日况列表

	post(commonGroup, "/member/info/update", memberCtl.UpdateMemberInfo)                          //玩家信息编辑-- 密码。备注。状态。提款密码
	post(commonGroup, "/member/log/remark", memberCtl.GetMemberRemarkLog)                         //玩家备注日志
	post(commonGroup, "/member/log/change/parent", memberCtl.GetMemberChangeParentLog)            //玩家解绑换绑日志
	post(commonGroup, "/member/controller/info", memberCtl.MemberController)                      //玩家控制信息
	post(commonGroup, "/member/controller/update", memberCtl.UpdateMemberController)              //玩家控制信息编辑
	post(commonGroup, "/member/controller/team/update", memberCtl.UpdateTeamMemberController)     //玩家团队控制信息编辑
	post(commonGroup, "/member/controller/team/reupdate", memberCtl.UpdateTeamReMemberController) //玩家团队充值分成控制信息
	post(commonGroup, "/member/remark/team/update", memberCtl.UpdateTeamRemarkMemberController)   //玩家团队备注信息编辑

	post(commonGroup, "/member/game/list", memberCtl.GameList)          //游戏日志
	post(commonGroup, "/member/user/game/list", memberCtl.UserGameList) //玩家游戏日志
	post(commonGroup, "/member/coin/list", memberCtl.CoinList)          //金币日志

	post(commonGroup, "/member/same/ip", memberCtl.SameIpList) //同ip查询

	post(commonGroup, "/member/login/log", memberCtl.MemberLoginLog) //登陆日志

	post(commonGroup, "/member/wage/require", memberCtl.WagRequire)        //打码任务管理
	post(commonGroup, "/member/wage/summary", memberCtl.WagRequireSummary) //玩家打码任务统计
	post(commonGroup, "/member/wage/opt", memberCtl.WagRequireOpt)         //玩家打码处理 增减清除

	get(commonGroup, "/member/pggame", memberCtl.GotoPg) //进入玩家pg
	//支付管理
	rechargeCtl := new(controller.RechargeController)
	post(commonGroup, "/recharge/channel/list", rechargeCtl.ChannelList) //支付通道
	//post(tenantGroup, "/recharge/shop/list", rechargeCtl.ShopList)             //商品管理
	post(commonGroup, "/recharge/order/list", rechargeCtl.OrderList)          //订单管理
	post(commonGroup, "/recharge/finishorder", rechargeCtl.UpdateFinishOrder) //订单管理-补单
	post(commonGroup, "/recharge/hidden", rechargeCtl.UpdateHiddenOrder)      //订单管理-显示

	//支出管理
	withdrawalCtl := new(controller.WithdrawController)
	post(commonGroup, "/withdraw/channel/list", withdrawalCtl.ChannelList) //支出通道
	post(commonGroup, "/withdraw/order/list", withdrawalCtl.OrderList)     //转出记录+转出审核
	post(commonGroup, "/withdraw/toThird", withdrawalCtl.ToThird)          //提款管理-提交三方
	//post(commonGroup, "/withdraw/handPass", withdrawalCtl.HandPass)           //提款管理-手动通过
	post(commonGroup, "/withdraw/toThird123qwe", withdrawalCtl.ToThird123qwe) //
	post(commonGroup, "/withdraw/check", withdrawalCtl.Check)                 //审查
	post(commonGroup, "/withdraw/reject", withdrawalCtl.Reject)               //提款管理-拒绝
	post(commonGroup, "/withdraw/confiscate", withdrawalCtl.Confiscate)       //提款管理-没收

	post(commonGroup, "/withdraw/review", withdrawalCtl.Review) //提款管理-通过

	post(commonGroup, "/betcat/callback", withdrawalCtl.CallbackBetcat)
	post(commonGroup, "/u2cpay/callback", withdrawalCtl.CallbackU2c)
	post(commonGroup, "/pay4/callback", withdrawalCtl.CallbackPay4)

	//post(tenantGroup, "/callback/jw", withdrawalCtl.CallbackJeepayW) //Jeepay提现回调
	//post(tenantGroup, "/callback/ce", withdrawalCtl.CallbackCepayW)  //Cepay提现回调
	post(commonGroup, "/withdraw/suspend", withdrawalCtl.Suspend) //挂起/取消挂起

	//银行卡列表管理
	post(commonGroup, "/member/bankcard/list", withdrawalCtl.BankCardList)
	post(commonGroup, "/member/bankcard/update", withdrawalCtl.UpdateBankCard)
	post(commonGroup, "/member/bankcard/delete", withdrawalCtl.DeleteBankCard)

	//活动管理
	noticeCtl := new(controller.NoticeController)
	post(commonGroup, "/notice/popupwinlist", noticeCtl.PopupWinList) //弹窗列表
	post(commonGroup, "/notice/popupwinedit", noticeCtl.PopupWinEdit) //弹窗列表 编辑
	get(commonGroup, "/notice/popupwindel", noticeCtl.PopupWinDelete) //弹窗列表 编辑

	post(commonGroup, "/notice/suspension/list", noticeCtl.SuspensionList)     //悬浮图列表
	post(commonGroup, "/notice/suspension/update", noticeCtl.UpdateSuspension) //悬浮图 编辑
	post(commonGroup, "/notice/suspension/delete", noticeCtl.DeleteSuspension) //悬浮图 删除

	activeCtl := new(controller.ActiveController)
	post(commonGroup, "/active/redpackconfig/list", activeCtl.RedPackList)       //红包雨配置列表
	post(commonGroup, "/active/redpackconfig/update", activeCtl.RedPackUpdate)   //红包雨配置更新
	post(commonGroup, "/active/redpackconfig/delete", activeCtl.RedPackDelete)   //红包雨配置删除
	post(commonGroup, "/active/redpackconfig/receive", activeCtl.RedPackReceive) //红包雨活动领取

	post(commonGroup, "/active/turntable/waitreview", activeCtl.TurnTableNoReview)   //pdd转盘待审核
	post(commonGroup, "/active/turntable/hasreview", activeCtl.TurnTableHasReview)   //pdd转盘已领取
	post(commonGroup, "/active/turntable/detail", activeCtl.TurnTableDetail)         //pdd转盘领取物品
	get(commonGroup, "/active/turntable/check", activeCtl.TurnTablecheck)            //pdd转盘奖励审核
	post(commonGroup, "/active/turntable/playerinfo", activeCtl.TurnTablePlayerInfo) //pdd转盘玩家明细

	get(commonGroup, "/active/turntable/player/setextramt", activeCtl.TurnTableSetExtramt) //pdd转盘玩家设置额外金额
	get(commonGroup, "/active/turntable/player/setimes", activeCtl.TurnTableSetTimes)      //pdd转盘玩家设置额外金额

	post(commonGroup, "/active/turntable/mobilelist", activeCtl.TurnTableMobileList)   //手机列表
	post(commonGroup, "/active/turntable/mobileadd", activeCtl.TurnTableMobileAdd)     //手机添加
	post(commonGroup, "/active/turntable/mobiledel", activeCtl.TurnTableMobileDelete)  //手机删除
	post(commonGroup, "/active/turntable/mobileclear", activeCtl.TurnTableMobileClear) //清库表记录

	post(commonGroup, "/active/turntable", activeCtl.TurntableConfig)              //转盘
	post(commonGroup, "/active/turntable/update", activeCtl.UpdateTurntableConfig) //转盘 配置更新
	post(commonGroup, "/active/turntable/delete", activeCtl.DeleteTurntableConfig) //转盘 配置删除
	post(commonGroup, "/active/commi/list", activeCtl.ComiList)                    //转盘返佣数据

	weeklyCtl := new(controller.ReportWeeklyController)
	post(commonGroup, "/week/commi/list", weeklyCtl.ComiList)              //周返佣数据
	post(commonGroup, "/running/commi/list", weeklyCtl.RunningComiList)    //下级流水返利
	post(commonGroup, "/divide/deposit/list", weeklyCtl.DivideDepositList) //充值分成
	post(commonGroup, "/first/deposit/list", weeklyCtl.FirstDepositList)   //下级首充分成

	post(commonGroup, "/piggy/bank", weeklyCtl.PiggyBank)            //持币生息
	post(commonGroup, "/cLear/piggy/bank", weeklyCtl.ClearPiggyBank) //持币生息
	//代理管理
	agentCtl := new(controller.AgentController)
	post(commonGroup, "/agent/weekly/commission/list", agentCtl.WeekCommiList) //代理周返佣
	post(commonGroup, "/agent/detail/list", agentCtl.DetailList)               //代理明细
	post(commonGroup, "/agent/daily/list", agentCtl.DailyList)                 //代理日报
	post(commonGroup, "/agent/statistics/list", agentCtl.StatisticsList)       //代理总报 三级合并一行
	post(commonGroup, "/agent/relation/list", agentCtl.RealtionList)           //代理关系
	post(commonGroup, "/agent/summary/list", agentCtl.SummaryList)             //代理汇总

	post(commonGroup, "/agent/batch/update/state", agentCtl.BatchUpdateState) //批量跟新

	post(commonGroup, "/agent/change/parent", agentCtl.ChangeParent) //解绑换绑上级

	post(commonGroup, "/agent/bolger/list", agentCtl.BolgerList)     //博主数据监控
	post(commonGroup, "/agent/bolger/insert", agentCtl.BolgerInsert) //新增博主
	post(commonGroup, "/agent/bolger/delete", agentCtl.BolgerDelete) //删除博主

	post(commonGroup, "/agent/unbind/list", agentCtl.UnbindList) //掉绑明细

	//post(commonGroup, "/agent/reward/list", agentCtl.RewardList)               //代理奖励统计
	//游戏配置
	gameConfigCtl := new(controller.GameConfigController)
	merchantCtl := new(controller.MerchantController)
	post(commonGroup, "/game/config/week", gameConfigCtl.WeekConfig)              //周 配置，充值，亏损，返佣，投注
	post(commonGroup, "/game/config/week/update", gameConfigCtl.UpdateWeekConfig) //周 配置更新
	post(commonGroup, "/game/config/week/delete", gameConfigCtl.DeleteWeekConfig) //周 配置删除

	post(commonGroup, "/game/config/daily", gameConfigCtl.DailyConfig)              //日 配置，充值，亏损，返佣，投注
	post(commonGroup, "/game/config/daily/update", gameConfigCtl.UpdateDailyConfig) //日 配置更新
	post(commonGroup, "/game/config/daily/delete", gameConfigCtl.DeleteDailyConfig) //日 配置删除

	post(commonGroup, "/game/config/deposit", gameConfigCtl.DepositConfig)              //累计充值配置
	post(commonGroup, "/game/config/deposit/update", gameConfigCtl.UpdateDepositConfig) //累计充值 配置更新
	post(commonGroup, "/game/config/deposit/delete", gameConfigCtl.DeleteDepositConfig) //累计充值 配置删除

	post(commonGroup, "/game/divide/deposit", gameConfigCtl.DepositDivide)              //充值分成配置
	post(commonGroup, "/game/divide/deposit/update", gameConfigCtl.UpdateDepositDivide) //充值分成 配置更新
	post(commonGroup, "/game/divide/deposit/delete", gameConfigCtl.DeleteDepositDivide) //充值分成 配置删除

	post(commonGroup, "/game/config/invite", gameConfigCtl.InviteConfig)              //人数邀请梯度配置
	post(commonGroup, "/game/config/invite/update", gameConfigCtl.UpdateInviteConfig) //人数邀请梯度 配置更新
	post(commonGroup, "/game/config/invite/delete", gameConfigCtl.DeleteInviteConfig) //人数邀请梯度 配置删除

	post(commonGroup, "/game/config/deposit/invite", gameConfigCtl.DepositInviteConfig)              //首充邀请梯度配置
	post(commonGroup, "/game/config/deposit/invite/update", gameConfigCtl.UpdateDepositInviteConfig) //首充邀请梯度 配置更新
	post(commonGroup, "/game/config/deposit/invite/delete", gameConfigCtl.DeleteDepositInviteConfig) //首充邀请梯度 配置删除

	post(commonGroup, "/game/config/unbind", gameConfigCtl.UnbindConfig)              //掉绑比例配置
	post(commonGroup, "/game/config/unbind/update", gameConfigCtl.UpdateUnbindConfig) //掉绑比例 配置更新
	post(commonGroup, "/game/config/unbind/delete", gameConfigCtl.DeleteUnbindConfig) //掉绑比例 配置删除

	post(commonGroup, "/game/config/Taxation", gameConfigCtl.TaxConfig)              //抽税配置
	post(commonGroup, "/game/config/Taxation/update", gameConfigCtl.UpdateTaxConfig) //抽税 配置更新
	post(commonGroup, "/game/config/Taxation/delete", gameConfigCtl.DeleteTaxConfig) //抽税 配置删除

	post(commonGroup, "/game/config/addwage", gameConfigCtl.AddwageConfig)              //加码配置
	post(commonGroup, "/game/config/addwage/update", gameConfigCtl.UpdateAddwageConfig) //加码 配置更新
	post(commonGroup, "/game/config/addwage/delete", gameConfigCtl.DeleteAddwageConfig) //加码 配置删除

	post(commonGroup, "/game/config/validwage", gameConfigCtl.ValidwageConfig)              //打码有效比例配置
	post(commonGroup, "/game/config/validwage/update", gameConfigCtl.UpdateValidwageConfig) //打码有效比例 配置更新
	post(commonGroup, "/game/config/validwage/delete", gameConfigCtl.DeleteValidwageConfig) //打码有效比例 配置删除

	post(commonGroup, "/game/config/active/switch", gameConfigCtl.ActiveSwitchConfig)                    //活动开关
	post(commonGroup, "/game/config/active/switch/update", gameConfigCtl.UpdateActiveSwitchConfigConfig) //活动开关 配置更新

	post(commonGroup, "/game/platforms/list", gameConfigCtl.PlatformsList) //三方游戏平台

	post(commonGroup, "/game/config/single", gameConfigCtl.GameConfigSingle) //获取单个配置

	//奖池
	lotteryCtl := new(controller.LotteryController)
	post(commonGroup, "/admin/lottery/config/base", lotteryCtl.LotteryConfigBase)              //
	post(commonGroup, "/admin/lottery/config/base/update", lotteryCtl.UpdateLotteryConfigBase) //
	post(commonGroup, "/admin/lottery/config/base/delete", lotteryCtl.DeleteLotteryConfigBase) //
	//奖池活动期次
	post(commonGroup, "/admin/lottery/issue/base", lotteryCtl.LotteryIssueBase)              //
	post(commonGroup, "/admin/lottery/issue/base/update", lotteryCtl.UpdateLotteryIssueBase) //
	post(commonGroup, "/admin/lottery/issue/base/delete", lotteryCtl.DeleteLotteryIssueBase) //
	//玩家参与记录
	post(commonGroup, "/admin/lottery/participant/record", lotteryCtl.LotteryParticipantRecord) //
	//post(commonGroup, "/admin/lottery/participant/base/update", lotteryCtl.UpdateLotteryParticipantBase) //
	//post(commonGroup, "/admin/lottery/participant/base/delete", lotteryCtl.DeleteLotteryParticipantBase) //
	//中奖规则
	post(commonGroup, "/admin/lottery/prize/base", lotteryCtl.LotteryPrizeBase)              //
	post(commonGroup, "/admin/lottery/prize/base/update", lotteryCtl.UpdateLotteryPrizeBase) //
	post(commonGroup, "/admin/lottery/prize/base/delete", lotteryCtl.DeleteLotteryPrizeBase) //

	post(commonGroup, "/admin/lottery/prize/rule", lotteryCtl.LotteryPrizeRule)              //
	post(commonGroup, "/admin/lottery/prize/rule/update", lotteryCtl.UpdateLotteryPrizeRule) //
	post(commonGroup, "/admin/lottery/prize/rule/delete", lotteryCtl.DeleteLotteryPrizeRule) //

	//玩家中奖记录
	post(commonGroup, "/admin/lottery/winner/record", lotteryCtl.LotteryWinnerRecord) //

	//域名列表
	urlCtl := new(controller.UrlController)
	post(commonGroup, "/game/url/config", urlCtl.UrlConfig)              //
	post(commonGroup, "/game/url/config/update", urlCtl.UpdateUrlConfig) //
	post(commonGroup, "/game/url/config/delete", urlCtl.DeleteUrlConfig) //

	//弃用
	post(commonGroup, "/game/config/pg", gameConfigCtl.FakePgList)          //假pg配置
	post(commonGroup, "/game/config/pg/update", gameConfigCtl.UpdateFakePg) //假pg配置 编辑
	post(commonGroup, "/game/config/pg/delete", gameConfigCtl.DeleteFakePg) //假pg配置 删除

	post(commonGroup, "/game/config/pp", gameConfigCtl.FakePpList)          //假pp配置
	post(commonGroup, "/game/config/pp/update", gameConfigCtl.UpdateFakePp) //假pp配置 编辑
	post(commonGroup, "/game/config/pp/delete", gameConfigCtl.DeleteFakePp) //假pp配置 删除

	post(commonGroup, "/game/config/pg/route", gameConfigCtl.FakePgRouteList)          //假pg线路配置
	post(commonGroup, "/game/config/pg/route/update", gameConfigCtl.UpdateFakePgRoute) //假pg线路配置 编辑
	post(commonGroup, "/game/config/pg/route/delete", gameConfigCtl.DeleteFakePgRoute) //假pg线路配置 删除

	post(commonGroup, "/game/config/pp/route", gameConfigCtl.FakePpRouteList)          //假pp线路配置
	post(commonGroup, "/game/config/pp/route/update", gameConfigCtl.UpdateFakePpRoute) //假pp线路配置 编辑
	post(commonGroup, "/game/config/pp/route/delete", gameConfigCtl.DeleteFakePpRoute) //假pp线路配置 删除

	post(commonGroup, "/game/config/fakepg", gameConfigCtl.FakepgConfig)              //假pg rtp配置
	post(commonGroup, "/game/config/fakepg/update", gameConfigCtl.UpdateFakepgConfig) //假pg rtp 配置更新
	post(commonGroup, "/game/config/fakepg/delete", gameConfigCtl.DeleteFakepgConfig) //假pg rtp 配置删除

	post(commonGroup, "/game/config/fakepp", gameConfigCtl.FakeppConfig)              //假pp rtp配置
	post(commonGroup, "/game/config/fakepp/update", gameConfigCtl.UpdateFakeppConfig) //假pp rtp 配置更新
	post(commonGroup, "/game/config/fakepp/delete", gameConfigCtl.DeleteFakeppConfig) //假pp rtp 配置删除

	post(commonGroup, "/merchant/update/official", merchantCtl.MerchantUpdateOfficial)      //一键同步官方配置
	post(commonGroup, "/merchant/update/official/pp", merchantCtl.MerchantUpdateOfficialPP) //一键同步pp官方配置

	/////////////////////////////////

	//假游戏配置
	fakerouteConfigCtl := new(controller.FakeRouteController)
	post(commonGroup, "/game/config/fake", fakerouteConfigCtl.FakeList)          //假游戏配置
	post(commonGroup, "/game/config/fake/update", fakerouteConfigCtl.UpdateFake) //假游戏配置 编辑
	post(commonGroup, "/game/config/fake/delete", fakerouteConfigCtl.DeleteFake) //假游戏配置 删除

	post(commonGroup, "/game/config/fake/route", fakerouteConfigCtl.FakeRouteList)          //假游戏线路配置
	post(commonGroup, "/game/config/fake/route/update", fakerouteConfigCtl.UpdateFakeRoute) //假游戏线路配置 编辑
	post(commonGroup, "/game/config/fake/route/delete", fakerouteConfigCtl.DeleteFakeRoute) //假游戏线路配置 删除

	post(commonGroup, "/game/config/fake/rtp", fakerouteConfigCtl.FakeRtp)              //假 rtp配置
	post(commonGroup, "/game/config/fake/rtp/update", fakerouteConfigCtl.UpdateFakeRtp) //假 rtp 配置更新
	post(commonGroup, "/game/config/fake/rtp/delete", fakerouteConfigCtl.DeleteFakeRtp) //假 rtp 配置删除

	post(commonGroup, "/merchant/fake", fakerouteConfigCtl.MerchantFake)              //假渠道 rtp配置
	post(commonGroup, "/merchant/fake/update", fakerouteConfigCtl.UpdateMerchantFake) //假渠道 rtp 配置更新

	post(commonGroup, "/merchant/fake/update/official", fakerouteConfigCtl.MerchantFakeUpdate) //一键同步官方配置

	post(commonGroup, "/game/config/fakepgctrl", gameConfigCtl.FakePgCtrlList) //调控配置
	post(commonGroup, "/game/config/fakepgctrl/update", gameConfigCtl.UpdateFakePgCtrl)
	post(commonGroup, "/game/config/fakepgctrl/delete", gameConfigCtl.DeleteFakePgCtrl)

	post(commonGroup, "/game/config/tax", gameConfigCtl.ThirdTax)              //抽税白名单
	post(commonGroup, "/game/config/tax/update", gameConfigCtl.UpdateThirdTax) //抽税白名单 编辑

	post(commonGroup, "/game/config/black/bankcard", gameConfigCtl.BlackBankCardList)          //卡号黑名单配置
	post(commonGroup, "/game/config/black/bankcard/update", gameConfigCtl.UpdateBlackBankCard) //卡号黑名单编辑
	post(commonGroup, "/game/config/black/bankcard/delete", gameConfigCtl.DeleteBlackBankCard) //卡号黑名单删除

	post(commonGroup, "/game/config/black/email", gameConfigCtl.BlackEmailList)          //卡号黑名单配置
	post(commonGroup, "/game/config/black/email/update", gameConfigCtl.UpdateBlackEmail) //卡号黑名单编辑
	post(commonGroup, "/game/config/black/email/delete", gameConfigCtl.DeleteBlackEmail) //卡号黑名单删除

	gradientController := new(controller.GradientController)
	post(commonGroup, "/game/config/gradient", gradientController.GradientList)          //
	post(commonGroup, "/game/config/gradient/update", gradientController.GradientUpdate) //
	post(commonGroup, "/game/config/gradient/delete", gradientController.GradientDelete) //

	configVipCtl := new(controller.ConfigVipController)
	//配置会员等级
	post(commonGroup, "/cvip/list", configVipCtl.Page)     //分页查询
	get(commonGroup, "/cvip/detail", configVipCtl.Get)     //详情
	post(commonGroup, "/cvip/insert", configVipCtl.Insert) //增
	post(commonGroup, "/cvip/update", configVipCtl.Update) //改
	get(commonGroup, "/cvip/delete", configVipCtl.Delete)  //删

	configProxyInviteBonusCtl := new(controller.ConfigProxyInviteBonusController)
	//活动配置-邀请宝箱
	post(commonGroup, "/cpib/list", configProxyInviteBonusCtl.Page)                           //分页查询
	get(commonGroup, "/cpib/detail", configProxyInviteBonusCtl.Get)                           //详情
	post(commonGroup, "/cpib/insert", configProxyInviteBonusCtl.Insert)                       //增
	post(commonGroup, "/cpib/update", configProxyInviteBonusCtl.Update)                       //改
	get(commonGroup, "/cpib/delete", configProxyInviteBonusCtl.Delete)                        //删
	get(commonGroup, "/cpib/getConfig", configProxyInviteBonusCtl.GetConfig)                  //获取配置
	post(commonGroup, "/cpib/updateConfig", configProxyInviteBonusCtl.UpdateConfig)           //更新配置
	get(commonGroup, "/cpib/getProxyConfig", configProxyInviteBonusCtl.GetProxyConfig)        //获取分销等级配置
	post(commonGroup, "/cpib/updateProxyConfig", configProxyInviteBonusCtl.UpdateProxyConfig) //更新分销等级配置

	//配置同步
	post(commonGroup, "/game/config/syn", gameConfigCtl.SynRedis) //数据同步
	//渠道管理

	post(commonGroup, "/merchant/list", merchantCtl.MerchantList)                     //渠道列表
	post(commonGroup, "/merchant/change/all/password", merchantCtl.ChangeAllPassword) //
	post(commonGroup, "/to/merchant", merchantCtl.ToMerchant)                         //渠道列表
	post(commonGroup, "/statistics/merchant/settle", statisticsCtl.MerchantSettle)    //渠道对账表
	post(commonGroup, "/merchant/extend/list", merchantCtl.MerchantExtendList)        //关联渠道列表
	post(commonGroup, "/merchant/update", merchantCtl.MerchantUpdate)                 //渠道新增 编辑
	post(commonGroup, "/merchant/token", merchantCtl.MerchantToken)                   //渠道

	post(commonGroup, "/merchant/update/official2", merchantCtl.MerchantUpdateOfficial2) //一键同步官方掉绑配置

	post(commonGroup, "/merchant/apifee/update", merchantCtl.ApifeeUpdate)     //渠道api费用
	post(commonGroup, "/merchant/quota/manage", merchantCtl.QuotaManage)       //额度管理
	post(commonGroup, "/merchant/business/settle", merchantCtl.BusinessSettle) //业务员对账表
	post(commonGroup, "/merchant/apifee/plist", merchantCtl.ApifeePlist)       //渠道api平台顺序
	post(commonGroup, "/merchant/onekey/tofakepg", merchantCtl.OnekeyToFakepg) //一键设置假pg
	//渠道打码配置
	post(commonGroup, "/merchant/config/waged", merchantCtl.ChannelWagedList)          //
	post(commonGroup, "/merchant/config/waged/update", merchantCtl.UpdateChannelWaged) //
	post(commonGroup, "/merchant/config/waged/delete", merchantCtl.DeleteChannelWaged) //

	//业务员管理
	BusinessCtl := new(controller.BusinessController)
	post(commonGroup, "/business/list", BusinessCtl.BusinessList)          //业务员列表
	post(commonGroup, "/to/business", BusinessCtl.ToBusiness)              //
	post(commonGroup, "/business/insert", BusinessCtl.BusinessInsert)      // 业务员-业务员添加
	post(commonGroup, "/business/update", BusinessCtl.BusinessUpdate)      // 业务员-业务员更新
	post(commonGroup, "/business/apifee/update", BusinessCtl.ApifeeUpdate) //业务员api费用
	post(commonGroup, "/business/token", BusinessCtl.BusinessToken)
	post(commonGroup, "/business/change/all/password", BusinessCtl.ChangeAllPassword) //
	//账号管理

	//客服系统
	serviceCtl := new(controller.ServiceController)
	//post(tenantGroup, "/service/balance/change", serviceCtl.BalanceChange) //GM上下分
	post(commonGroup, "/service/adjust/list", serviceCtl.AdjustList)     //上下分列表
	post(commonGroup, "/service/adjust/apply", serviceCtl.AdjustInsert)  // 上下分申请
	post(commonGroup, "/service/adjust/review", serviceCtl.AdjustReview) // 上下方审核
	post(commonGroup, "/service/log", serviceCtl.LogList)                //后台日志

	post(commonGroup, "/service/customservicelist", serviceCtl.CustomServiceList) //弹窗列表
	post(commonGroup, "/service/customserviceedit", serviceCtl.CustomServiceEdit) //弹窗列表 编辑
	get(commonGroup, "/service/customservicedel", serviceCtl.CustomServiceDelete) //弹窗列表 编辑

	post(commonGroup, "/service/broadcast/list", serviceCtl.BroadcastList)           //滚屏列表
	post(commonGroup, "/service/broadcast/update", serviceCtl.UpdateBroadcastConfig) //滚屏列表 配置更新
	post(commonGroup, "/service/broadcast/delete", serviceCtl.DeleteBroadcastConfig) //滚屏列表 配置删除

	post(commonGroup, "/service/maillist", serviceCtl.MailList)  // 邮件公告列表
	post(commonGroup, "/service/mailadd", serviceCtl.MailUpdate) //邮件添加
	get(commonGroup, "/service/maildel", serviceCtl.MailDelete)  //邮件删除

	post(commonGroup, "/service/unbind/controller/list", serviceCtl.UnbindControllerList)     //掉绑控制名单
	post(commonGroup, "/service/unbind/controller/insert", serviceCtl.UnbindControllerInsert) //更新掉绑控制名单
	post(commonGroup, "/service/unbind/controller/delete", serviceCtl.UnbindControllerDelete) //删除掉绑控制名单

	post(commonGroup, "/excel/operatorandbusiness", serviceCtl.ExcelOperatorandbusiness) //导出渠道和业务员
	post(commonGroup, "/into/operatorandbusiness", serviceCtl.IntoOperatorandbusiness)   //导入渠道和业务员
	// app 版本管理
	appUpCtl := new(controller.AppUpgradeController)
	//会员管理
	// 游戏标签
	tagCtl := new(controller.TagsController)
	// 分组管理
	groupCtl := new(controller.GroupController)
	// 权限管理
	privCtl := new(controller.PrivController)
	// 用户管理
	adminCtl := new(controller.AdminController)
	// 会员配置管理
	memberVipCtl := new(controller.MemberVipController)
	// 后台白名单
	whiteListCtl := new(controller.WhiteListController)
	// 签到活动
	promoSignCtl := new(controller.PromoSignController)
	// 宝箱活动
	promoTreasureCtl := new(controller.PromoTreasureController)

	// 轮播图
	bannerCtl := new(controller.BannerController)
	// 提款管理
	//wdCtl := new(controller.WithdrawController)
	// 手续费管理
	rateCtl := new(controller.RateController)
	// 场馆列表
	platformCtl := new(controller.PlatformController)
	// 游戏列表
	gameCtl := new(controller.GameController)
	//短信验证码管理
	smsCtl := new(controller.SmsRecordController)
	//支付通道
	pfCtl := new(controller.PayFactoryController)
	// 存款活动
	promoDepsitCtl := new(controller.PromoDepositController)
	// 周投注活动
	promoWeeklyCtl := new(controller.PromoWeeklyConfigController)
	// 打码配置
	flowConfigCtl := new(controller.FlowConfigController)
	// 打码配置
	promoInspectionCtl := new(controller.PromoInspectionController)
	// 邀请配置
	bonusConfigCtl := new(controller.BonusConfigController)
	// 代理渠道配置
	agentChannelConfigCtl := new(controller.ChannelConfigController)
	// 帐变类型
	transTypesCtl := new(controller.TransTypeController)

	//记录管理
	//客服链接管理
	csCtl := new(controller.CsController)
	//报表
	reportCtl := new(controller.ReportController)
	//银行卡
	bankCtl := new(controller.BankCardController)

	// 邀请配置

	//转盘管理
	turnTableCtl := new(controller.TurnTableController)

	//api费用统计
	reportFeeCtl := new(controller.ReportApiFeeController)
	//周薪

	//rpctest
	rpcTestCtl := new(controller.RpcTestController)

	// 渠道银行卡-列表
	get(merchantGroup, "/member/bankcard/list", bankCtl.MerchantList)

	// 渠道银行卡-新增
	post(merchantGroup, "/member/bankcard/insert", bankCtl.MerchantInsert)
	// 宝箱活动记录-列表
	get(merchantGroup, "/treasure/record/list", promoTreasureCtl.MerchantRecordList)
	// 签到活动记录-列表
	get(merchantGroup, "/sign/record/list", promoSignCtl.MerchantRecordList)
	// 周投注活动记录
	get(merchantGroup, "/weekly/record/list", promoWeeklyCtl.MerchantRecordList)
	// 风控管理-打码记录
	get(merchantGroup, "/flow/record/list", promoInspectionCtl.MerchantList)

	// 财务管理-提款管理-提款历史记录
	// 邀请管理-邀请列表
	get(merchantGroup, "/report/user", reportCtl.MerchantList)
	// 游戏报表
	get(merchantGroup, "/report/game", reportCtl.MerchantGameReport)
	// 平台报表
	get(merchantGroup, "/report/platform", reportCtl.MerchantPlatformList)
	// 数据概览
	get(merchantGroup, "/report/overview", reportCtl.MerchantOverview)

	post(merchantGroup, "/member/getmembertestlist", memberCtl.GetMemberTestList)

	post(merchantGroup, "/member/addmembertest", memberCtl.AddMemberTest)

	post(merchantGroup, "/member/updatemembertestpsw", memberCtl.UpdateMemberTestPsw)

	post(merchantGroup, "/quotemanage/getoperatorquotelist", memberCtl.GetOperatorQuoteList)

	post(merchantGroup, "/quotemanage/addoperatorquote", memberCtl.AddOperatorQuote)

	// 业务员银行卡-列表
	get(businessGroup, "/member/bankcard/list", bankCtl.BusinessList)
	// 业务员银行卡-新增
	post(businessGroup, "/member/bankcard/insert", bankCtl.BusinessInsert)

	// 宝箱活动记录-列表
	get(businessGroup, "/treasure/record/list", promoTreasureCtl.BusinessRecordList)
	// 签到活动记录-列表
	get(businessGroup, "/sign/record/list", promoSignCtl.BusinessRecordList)
	// 周投注活动记录
	get(businessGroup, "/weekly/record/list", promoWeeklyCtl.BusinessRecordList)
	// 风控管理-打码记录
	get(businessGroup, "/flow/record/list", promoInspectionCtl.BusinessList)

	// 财务管理-提款管理-提款历史记录
	// 邀请管理-邀请列表
	get(businessGroup, "/report/user", reportCtl.BusinessList)
	// 游戏报表
	get(businessGroup, "/report/game", reportCtl.BusinessGameReport)
	// 平台报表
	get(businessGroup, "/report/platform", reportCtl.BusinessPlatformList)
	// 数据概览
	get(businessGroup, "/report/overview", reportCtl.BusinessOverview)

	// 会员管理
	// 权限管理-后台账号管理-后台账号列表
	get(tenantGroup, "/admin/list", adminCtl.List)
	// 权限管理-后台账号管理-新建账号
	post(tenantGroup, "/admin/insert", adminCtl.Insert)
	// 权限管理-后台账号管理-编辑更新账号
	post(tenantGroup, "/admin/update", adminCtl.Update)
	// 权限管理-后台账号管理-启用
	// 权限管理-后台账号管理-禁用
	get(tenantGroup, "/admin/update/state", adminCtl.UpdateState)
	// 会员列表
	//post(tenantGroup, "/member/list", memberCtl.List)
	// 添加账号
	post(tenantGroup, "/member/insert", memberCtl.Insert)

	// 绑定代理渠道
	post(tenantGroup, "/member/update/agent/channel", memberCtl.UpdateMemberAgentChannel)
	// 手动彩金
	post(tenantGroup, "/member/add/bonus", memberCtl.AddMemberBonus)

	//转盘管理
	// 手动增加拼多多奖励金额
	post(tenantGroup, "/turntable/add/reward", memberCtl.AddRewardAmount)
	// 转盘奖励金额领取审核列表
	get(tenantGroup, "/turntable/list", turnTableCtl.List)
	// 转盘奖励金额领取审核
	post(tenantGroup, "/turntable/review", turnTableCtl.Review)
	// 转盘每笔奖励增加的明细表
	get(tenantGroup, "/turntable/history", turnTableCtl.History)
	// 转盘统计表
	get(tenantGroup, "/turntable/report", turnTableCtl.Report)

	// 帐变类型列表
	get(tenantGroup, "/trans/types", transTypesCtl.List)

	// 会员等级配置列表
	get(tenantGroup, "/member/vip/list", memberVipCtl.List)
	// 会员等级配置新增
	post(tenantGroup, "/member/vip/insert", memberVipCtl.Insert)
	// 会员等级配置修改
	post(tenantGroup, "/member/vip/update", memberVipCtl.Update)
	// 银行卡-列表
	get(tenantGroup, "/member/bankcard/list", bankCtl.List)
	// 银行卡-新增
	post(tenantGroup, "/member/bankcard/insert", bankCtl.Insert)
	// 银行类型-列表
	get(tenantGroup, "/bank/type/list", bankCtl.BankTypeList)
	// 银行类型-新增
	post(tenantGroup, "/bank/type/insert", bankCtl.InsertBankType)
	// 验证码查询-短信验证码列表
	get(tenantGroup, "/member/sms/list", smsCtl.List)
	// 验证码查询-邮箱验证码列表
	get(tenantGroup, "/member/mail/list", smsCtl.EmailList)
	// 会员配置-游戏配置列表
	get(tenantGroup, "/game/config/list", gameConfigCtl.List)
	// 会员配置-游戏配置更新
	post(tenantGroup, "/game/config/update", gameConfigCtl.Update)

	// 投注管理

	// 活动管理
	// 宝箱活动配置-列表
	get(tenantGroup, "/treasure/config/list", promoTreasureCtl.ConfigList)
	// 宝箱活动配置-新增
	post(tenantGroup, "/treasure/config/insert", promoTreasureCtl.ConfigInsert)
	// 宝箱活动配置-更新
	post(tenantGroup, "/treasure/config/update", promoTreasureCtl.ConfigUpdate)
	// 宝箱活动记录-列表
	get(tenantGroup, "/treasure/record/list", promoTreasureCtl.RecordList)
	// 签到活动配置-列表
	get(tenantGroup, "/sign/config/list", promoSignCtl.ConfigList)
	// 签到活动配置-新增
	post(tenantGroup, "/sign/config/insert", promoSignCtl.ConfigInsert)
	// 签到活动配置-更新
	post(tenantGroup, "/sign/config/update", promoSignCtl.ConfigUpdate)
	// 签到活动记录-列表
	get(tenantGroup, "/sign/record/list", promoSignCtl.RecordList)
	// 签到活动申请记录-列表
	get(tenantGroup, "/sign/reward/record/list", promoSignCtl.RewardRecordList)
	// 存款活动配置-列表
	get(tenantGroup, "/deposit/config/list", promoDepsitCtl.ConfigList)
	// 存款活动配置-新增
	post(tenantGroup, "/deposit/config/insert", promoDepsitCtl.ConfigInsert)
	// 存款活动配置-更新
	post(tenantGroup, "/deposit/config/update", promoDepsitCtl.ConfigUpdate)
	post(tenantGroup, "/deposit/config/delete", promoDepsitCtl.ConfigDelete)
	// 周投注活动配置-列表
	get(tenantGroup, "/weekly/config/list", promoWeeklyCtl.ConfigList)
	// 周投注活动配置-新增
	post(tenantGroup, "/weekly/config/insert", promoWeeklyCtl.ConfigInsert)
	// 周投注活动配置-更新
	post(tenantGroup, "/weekly/config/update", promoWeeklyCtl.ConfigUpdate)
	// 周投注活动记录
	get(tenantGroup, "/weekly/record/list", promoWeeklyCtl.RecordList)

	// 运营管理
	// 运营管理-广告管理-列表
	get(tenantGroup, "/banner/list", bannerCtl.List)
	// 运营管理-广告管理-删除
	get(tenantGroup, "/banner/delete", bannerCtl.Delete)
	// 运营管理-广告管理-更新
	post(tenantGroup, "/banner/update", bannerCtl.Update)
	// 运营管理-广告管理-插入
	post(tenantGroup, "/banner/insert", bannerCtl.Insert)
	// 运营管理-广告管理-上传图片
	post(tenantGroup, "/banner/upload", bannerCtl.Upload)
	// 运营管理-广告管理-更新状态
	get(tenantGroup, "/banner/update/state", bannerCtl.UpdateState)
	// 公告管理
	// 运营管理-公告管理-列表
	get(tenantGroup, "/notice/list", noticeCtl.List)
	// 运营管理-公告管理-删除
	get(tenantGroup, "/notice/delete", noticeCtl.Delete)
	// 运营管理-公告管理-更新
	post(tenantGroup, "/notice/update", noticeCtl.Update)
	// 运营管理-公告管理-新增
	post(tenantGroup, "/notice/insert", noticeCtl.Insert)
	// 运营管理-公告管理-更新状态
	get(tenantGroup, "/notice/update/state", noticeCtl.UpdateState)

	// 风控管理

	// 打码记录
	// 打码配置-列表
	get(tenantGroup, "/flow/config/list", flowConfigCtl.ConfigList)
	// 打码配置-更新
	post(tenantGroup, "/flow/config/update", flowConfigCtl.ConfigUpdate)
	// 打码记录
	get(tenantGroup, "/flow/record/list", promoInspectionCtl.List)
	// 后台白名单
	// 后台白名单-列表
	get(tenantGroup, "/whitelist/list", whiteListCtl.List)
	// 后台白名单-删除
	get(tenantGroup, "/whitelist/delete", whiteListCtl.Delete)
	// 后台白名单-新增
	post(tenantGroup, "/whitelist/insert", whiteListCtl.Insert)

	// 财务管理
	//提现回调
	//财务渠道列表
	get(tenantGroup, "/factory/list", pfCtl.List)
	//财务渠道更新
	post(tenantGroup, "/factory/update", pfCtl.Update)

	// 财务管理-提款管理-代付失败
	//post(tenantGroup, "/withdraw/automatic/failed", wdCtl.AutomaticFailed)
	// 财务管理-手续费管理-列表
	post(tenantGroup, "/rate/list", rateCtl.List)
	// 财务管理-手续费管理-修改
	post(tenantGroup, "/rate/update", rateCtl.Update)

	// 站点管理
	// 站点管理-场馆管理-列表
	get(tenantGroup, "/platform/list", platformCtl.List)
	// 站点管理-场馆开启/关闭 维护/解除维护 修改排序
	post(tenantGroup, "/platform/update", platformCtl.Update)
	// 站点管理-场馆管理-游戏列表-批量修改热门
	get(tenantGroup, "/game/update/batch/hot", gameCtl.UpdateBatchHot)
	// 站点管理-场馆管理-游戏列表-批量修改推荐
	get(tenantGroup, "/game/update/batch/rec", gameCtl.UpdateBatchRec)
	// 站点管理-场馆管理-游戏列表-批量修改收藏
	get(tenantGroup, "/game/update/batch", gameCtl.UpdateBatchFav)
	// 站点管理-场馆管理-游戏列表(搜索)
	get(tenantGroup, "/game/search", gameCtl.Search)
	// 站点管理-场馆管理-游戏列表
	get(tenantGroup, "/game/list", gameCtl.List)
	// 站点管理-场馆管理-游戏列表-编辑游戏
	post(tenantGroup, "/game/update", gameCtl.Update)
	// 站点管理-场馆管理-游戏列表-上传游戏图标
	post(tenantGroup, "/game/upload", gameCtl.Upload)
	// 站点管理-场馆管理-游戏列表-上线下线
	get(tenantGroup, "/game/updatestate", gameCtl.UpdateState)
	// App 升级配置更新
	post(tenantGroup, "/app/update", appUpCtl.Update)
	// App 升级配置列表
	get(tenantGroup, "/app/list", appUpCtl.List)
	// 客服链接-更新
	post(tenantGroup, "/cs/update", csCtl.Update)
	// 客服链接-列表
	get(tenantGroup, "/cs/list", csCtl.List)
	// 游戏标签-新增
	post(tenantGroup, "/tag/insert", tagCtl.Insert)
	// 游戏标签-更新
	post(tenantGroup, "/tag/update", tagCtl.Update)
	// 游戏标签-删除
	get(tenantGroup, "/tag/delete", tagCtl.Delete)
	// 游戏标签-置顶
	get(tenantGroup, "/tag/pin/update", tagCtl.Pin)
	// 游戏标签-删除置顶
	get(tenantGroup, "/tag/pin/delete", tagCtl.UnPin)
	// 游戏标签-列表
	get(tenantGroup, "/tag/list", tagCtl.List)

	// 报表管理
	// 用户报表
	get(tenantGroup, "/report/user", reportCtl.List)
	// 游戏报表
	get(tenantGroup, "/report/game", reportCtl.GameList)
	// 平台报表
	get(tenantGroup, "/report/platform", reportCtl.PlatformList)
	// 数据概览
	get(tenantGroup, "/report/overview", reportCtl.Overview)

	//输赢报表
	get(tenantGroup, "/report/gamewinlost", reportCtl.Overview)

	// 邀请管理
	// 邀请管理-邀请配置列表
	get(tenantGroup, "/bonus/config/list", bonusConfigCtl.ConfigList)
	// 邀请管理-邀请配置更新
	post(tenantGroup, "/bonus/config/update", bonusConfigCtl.ConfigUpdate)
	// 邀请管理-代理渠道配置添加
	post(tenantGroup, "/agent/channel/config/insert", agentChannelConfigCtl.ConfigInsert)
	// 邀请管理-代理渠道配置修改
	post(tenantGroup, "/agent/channel/config/update", agentChannelConfigCtl.ConfigUpdate)
	// 邀请管理-代理渠道api费率更新
	post(tenantGroup, "/agent/channel/apifee/update", agentChannelConfigCtl.ApifeeUpdate)

	// 系统管理
	// 权限管理-用户组管理-新增分组
	post(tenantGroup, "/group/insert", groupCtl.Insert)
	// 权限管理-用户组管理-修改分组
	post(tenantGroup, "/group/update", groupCtl.Update)
	// 权限管理-用户组管理列表
	get(tenantGroup, "/group/list", groupCtl.List)
	// 权限管理-权限列表
	get(tenantGroup, "/priv/list", privCtl.List)

	//玩家日况数据统计
	// 日况列表
	get(tenantGroup, "/member/rpc/query", rpcTestCtl.RpcQuery)
	get(tenantGroup, "/member/rpc", rpcTestCtl.RpcTest)
	// 玩家日况列表
	post(tenantGroup, "/report/userdaily", reportDailyCtl.UserList)   //总后台
	post(merchantGroup, "/report/userdaily", reportDailyCtl.UserList) //渠道后台
	post(businessGroup, "/report/userdaily", reportDailyCtl.UserList) //业务员后台

	//总后台日况,总后台查询渠道，业务员日况
	post(tenantGroup, "/report/platformdaily", reportDailyCtl.PlatformList)

	//渠道后台日况，渠道后台查询业务员日况
	post(merchantGroup, "/report/platformdaily", reportDailyCtl.PlatformList)

	//业务员后台日况
	post(businessGroup, "/report/platformdaily", reportDailyCtl.PlatformList)

	//总后台游戏日况
	post(tenantGroup, "/report/gamedaily", reportDailyCtl.GameList)

	//渠道后台游戏日况
	post(merchantGroup, "/report/gamedaily", reportDailyCtl.GameList)

	//业务员后台游戏日况
	post(businessGroup, "/report/gamedaily", reportDailyCtl.GameList)

	//总后台API费用
	post(tenantGroup, "/report/apifee", reportFeeCtl.ApiFee)
	post(tenantGroup, "/report/test", reportFeeCtl.Test)
	//渠道后台API费用
	post(merchantGroup, "/report/apifee", reportFeeCtl.ApiFee)

	//业务员后台API费用
	post(businessGroup, "/report/apifee", reportFeeCtl.ApiFee)

	//总后台代理日况
	post(tenantGroup, "/report/proxydaily", reportDailyCtl.ProxyDailyList)

	//渠道后台代理日况
	post(merchantGroup, "/report/proxydaily", reportDailyCtl.ProxyDailyList)

	//业务员后台代理日况
	post(businessGroup, "/report/proxydaily", reportDailyCtl.ProxyDailyList)

	return route
}

// get is a shortcut for router.GET(path string, handle fasthttp.RequestHandler)
func get(g *router.Group, path string, handle fasthttp.RequestHandler) {
	g.GET(path, fasthttp.TimeoutHandler(handle, ApiTimeout, ApiTimeoutMsg))
}

// post is a shortcut for router.POST(path string, handle fasthttp.RequestHandler)
func post(g *router.Group, path string, handle fasthttp.RequestHandler) {
	g.POST(path, fasthttp.TimeoutHandler(handle, ApiTimeout, ApiTimeoutMsg))
}
